﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;

namespace EQual.MainModule.Employees.DetailsViews
{
    /// <summary>
    /// Interaction logic for EmployeesExperianceView.xaml
    /// </summary>
    public partial class EmployeesExperianceView : UserControl, EQual.Infrastructure.MVPFramework.Views.IListView<object, object>
    {
        public EmployeesExperianceView()
        {
            InitializeComponent();
        }

        #region IListView<Employee,object> Members

        public object Model
        {
            get
            {
                throw new NotImplementedException();
            }
            set
            {
                this.DataContext = value;
            }
        }


        #endregion

        private void dataGrid1_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {

        }

        private void dataGrid1_RowEditEnding(object sender, Microsoft.Windows.Controls.DataGridRowEditEndingEventArgs e)
        {
            ItemAdded(this, new Microsoft.Practices.Composite.Events.DataEventArgs<object >(dataGrid1 .SelectedItem ));

        }

        #region IListView<object,object> Members


        public event EventHandler<Microsoft.Practices.Composite.Events.DataEventArgs<object>> ItemSelected;

        public event EventHandler<Microsoft.Practices.Composite.Events.DataEventArgs<object>> ItemDeleted;

        public event EventHandler<Microsoft.Practices.Composite.Events.DataEventArgs<object>> ItemAdded;

        #endregion
    }
}
